import request from "@/utils/request";

// 获取全部课程信息
export const getAllcourse=(data)=>{
    return request({
        url: '/course/getAll',
        method: 'get',
        params: {
            page: data.page,
            pagesize: data.pagesize,
        }
    })
}
// 查看课程详情
export const getcourse=(data)=>{
    return request({
        url: '/course/getCourse',
        method: 'get',
        params: {
            id:data
        }
    })
}
export const getRecomment=(data)=>{
    return request({
        url: '/course/getRecomment',
        method: 'get',
        params: {
            id:data
        }
    })
}

// 记录用户点击行为
export const recordUserInteraction=(data)=>{
    return request({
        url: '/course/recordUserInteraction',
        method: 'post',
        data:data
    })
}